package com.zretc.service.impl;

import java.util.Map;

import com.zretc.dao.FansDao;
import com.zretc.dao.impl.FansDaoImpl;
import com.zretc.entity.Fans;
import com.zretc.service.FansService;
import com.zretc.util.PageInfo;

public class FansServiceImpl implements FansService {
	private FansDao fansDao = new FansDaoImpl();
	@Override
	public int addFans(Integer accountId, Integer fansId) {
		return fansDao.insertFans(accountId, fansId);
	}

	@Override
	public Fans getFans(Integer accountId, Integer fansId) {
		
		return fansDao.findFans(accountId, fansId);
	}

	@Override
	public int deleteFans(Integer accountId, Integer fansId) {
		return fansDao.deleteFans(accountId, fansId);
	}

	@Override
	public int fansCount(Integer accountId) {
		return fansDao.fansCount(accountId);
	}

	@Override
	public PageInfo<Fans> getAccountByFansId(Map<String, String> map) {
		// TODO Auto-generated method stub
		return fansDao.findAccountByFansId(map);
	}

	@Override
	public PageInfo<Fans> getFansByAccountId(Map<String, String> map) {
		// TODO Auto-generated method stub
		return fansDao.findFansByAccountId(map);
	}
}
